GetDeviceId

Definition:

GetDeviceId()

 

Description:

Obtain the ID of the device the Script is running on.

 

Platforms:

All

 

Parameters:

none

 

Returns:

String containing the ID of the current device.

 

Notes:

The format of the ID returned depends upon the type of device:

Device type

Description

ID Format

Android device

Smartphone or tablet powered by Android.

Android:<deviceID>

where <deviceID> is the ANDROID_ID, a random hexadecimal number generated on the first boot of the device. Note that this ID can be changed on a rooted device and could change on a factory reset.

iOS device

Apple iPhone or iPad.

<devicetype>:<deviceID>

where <devicetype> will be either iPad or iPhone, as appropriate and the <deviceID> will be a randomly-generated case-sensitive 22-character alpha-numeric string.

  • The Device ID is linked to your developer account in the Apple Developer Enterprise Program or Apple Developer Program, which means that pre-configured Digitise Apps Clients and Standalone Apps which are signed with Distribution Certificates from different Apple developer accounts will produce different Device IDs if run on the same device.
  • If you are upgrading to Digitise Apps from a version of its predecessor MX, in MX v10.0 or earlier devices were identified as: <devicetype>:<deviceID>, where <deviceID> was a unique 11 character case-sensitive alpha-numeric string, except for devices running a version of iOS earlier than v7, which were identified as:<devicetype>:<deviceMACaddress>.

Windows desktop or tablet

Computer or tablet PC running Windows and a version of the Windows Desktop Client or Windows Universal Client.

If the device is running the Windows Desktop Client the ID takes the form: Windows:<MACaddress>.

If the device is running the Windows Universal Client the ID takes the form: Windows:<deviceID> where the <deviceID> will be a string consisting of eight groups of numbers separated by hyphens derived from the device's MAC address.